“El Camino: A Breaking Bad Movie” gave fans the biggest cameo near the end of the film, and a lot of work went into keeping that surprise under wraps.

Netflix’s movie sequel, which was written and directed by “Breaking Bad” showrunner Vince Gilligan, saw the return of Walter White (played by Bryan Cranston) in the form of a flashback near the end of the film. The moment took place after Walt and Jesse’s (Aaron Paul) four-day meth-making marathon from season two, episode nine (“4 Days Out”).

In the flashback, Jesse was seen taking a much-needed tub bath, talking to a girl on the phone (Jane Margolis), and walking out of a hotel with Walt. Then, they went to a diner, where Jesse piled food onto a plate because the pair’s food and water supply got depleted while cooking. At the table, Walt began to cough. You could also see their RV outside the eatery, with duct tape covering the bullet holes on the door.

Here's how that top-secret cameo came together.

Read more: 12 'Breaking Bad' stars who returned for Netflix's sequel movie 'El Camino'

The flashback was filmed in January when Cranston had a day off from his starring role in Broadway's 'Network'

bryan cranston broadway network opening night december 2018

Foto: From left to right: Tatiana Maslany, Bryan Cranston, and Tony Goldwyn at the opening night of "Network" at the Belasco Theatre on Thursday, December 6, 2018.sourceGreg Allen/Invision/AP

Cranston portrayed anchorman Howard Beale in the Broadway adaptation of a 1976 movie of the same name. Due to his tight schedule, Gilligan told USA Today that the actor was only in New Mexico for 36 hours.

Cranston told Rolling Stone that he completed a matinee show on the first Sunday in January and traveled from Teterboro, New Jersey, to the movie set. He filmed the diner scene on Monday and completed the hotel part on Tuesday. Later that day, he headed back to New York City to continue his role in "Network."

A private jet was used to prevent Cranston from being detected by fans and paparazzi while traveling to and from Albuquerque

bryan cranston el camino premiere october 2019

Foto: Bryan Cranston at the Los Angeles premiere of "El Camino: A Breaking Bad Movie" in October 2019.sourceJordan Strauss/Invision/AP

"Netflix has a lot of money," Paul told "Entertainment Tonight."

According to The Hollywood Reporter, using private transportation also avoided any possible hiccups with commercial airlines.

Gilligan told USA Today that in addition to using a private jet, "when he landed at the Albuquerque airport, we put a bag over his head, put him in a tinted car and then drove him to the set that way."

The actor also stayed in an Airbnb

bryan cranston el camino flashback

Foto: Bryan Cranston in "El Camino."sourceNetflix

Cranston told Rolling Stone that it was "almost like a Witness Protection situation."

To get back into character, Cranston re-watched the episode that the flashback took place during

walt jesse four days out season two ep nine

Foto: Bryan Cranston and Aaron Paul on season two of "Breaking Bad."sourceAMC

"I hadn't seen it since it aired, so I did want to go back and get a sense of what my relationship with Jesse Pinkman was at that moment, what we had gone through," the actor told Rolling Stone.

He continued: "Just to get my head straight about how I felt at that time, and the level of despair and anxiety that the character was involved with. It was literally 10 years ago that I had last seen that episode, so it was extremely helpful."

Paul and Cranston wore cloaks to conceal their identities

aaron paul bryan cranston 2013 emmys

Foto: Aaron Paul and Bryan Cranston met on the set of "Breaking Bad."sourceJordan Strauss/Invision/AP

Cranston told Rolling Stone that he "looked like someone from 'The Handmaid's Tale'" and couldn't see in the disguise. Meanwhile, Paul told Entertainment Weekly that they resembled "Star Wars" characters.

"I also thought that maybe those clothes drew a lot more attention to us? But I don't know. Obviously it worked," he said.

The costars couldn't hang out together, or it could lead to speculation about the project

breaking bad el camino walt jesse flashback

Foto: Bryan Cranston and Aaron Paul in "El Camino."sourceNetflix

Entertainment Weekly said that it was a precaution in case the paparazzi photographed them together. However, Cranston told Rolling Stone that he was able to convince Paul to host a party at his house on the day of filming, "which was a beautiful night together."

Read more: 37 celebrity best friends who met on set

Cranston wore a bald cap and visual effects were used to shrink the size of his head

bryan cranston breaking bad el camino then and now

Foto: On the left is Bryan Cranston on season two of "Breaking Bad." On the right is the actor in "El Camino."sourceAMC and Netflix

As part of his role in "Network," Cranston couldn't shave off his hair and transform back into his "Breaking Bad" character. The makeup department (comprised of "The Walking Dead" crew members Greg Nicotero, Garrett Immel, and Carey Jones) constructed a bald cap for the actor to wear.

"We had to get these amazing makeup artists to give us the world's best bald cap, but we also had to get a little digital (effects) help to shrink Bryan's head so it didn't look bulbous with the bald cap on," Gilligan told USA Today. "It was a real group effort making all of these things match as closely as possible to this decade-old episode of television."

The people in the diner scene were actually crew members and their relatives

el camino diner jesse

Foto: Aaron Paul in "El Camino."sourceNetflix

"We needed that diner to be filled with people that we could trust to not leak this information," Paul told Entertainment Weekly. "And also just to be a part of it. We wanted to be surrounded by loved ones, to be a part of this really cool day."